<?php
if(!defined('IN_WOGU')) {
    exit('Access Denied');
}

Loader::loadUserModel('RlModel', false, 'admin');

class FrontController extends Controller
{
    protected $_lang = null;
    protected $_rl = null;
    protected $_admin = null;
    
    protected function _init() {
        $this->_lang = Loader::loadLang('admin', 'admin');
        $this->_initFront();
    }
    
    public function getRl() {
        if(!$this->_rl) {
            $this->_rl = new RlModel();
        }
        
        return $this->_rl;
    }
    
    public function getAdmin() {
        if(!$this->_admin) {
            $this->_admin = $this->getRl()->getAdmin(array('userid' => $_SESSION[RlModel::USERID]));
        }
        
        return $this->_admin;
    }
    
    protected function _initFront() {}
}